home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_06_06
/
v6n6089a.txt
< prev
next >
Wrap
Text File
|
1989-09-26
|
325b
|
16 lines
\NLETTER\6.6\CURVES5.PRGProgram 5
incr1 = 2*(dy-dx);
incr2 = 2*dy;
r = y1;
p = 2dy - 2dx;
for (xi=x1; xi<=x2; xi++)
{
plot(xi,r);
if (p >= 0)
{
r++; p += incr1;
}
else p += incr2;
}